package org.springframework.samples.webflow.dao;

import java.io.Serializable;

public class Criteria implements Serializable {

	private static final long serialVersionUID = 1870955347968811374L;

	public enum Operator {
		
		EQUALS("="),
		LIKE(" like ");
		
		private String expresion;
		
		private Operator(String expresion) {
			this.expresion = expresion;
		}
		
		public String getExpresion() {
			return this.expresion;
		}
	}
	
	private Object value;
	private Operator operator;
	
	public Criteria(Operator operator, Object value) {
		this.operator = operator;
		this.value = value;
	}
	
	public Object getValue() {
		return value;
	}
	
	public void setValue(Object value) {
		this.value = value;
	}
	
	public Operator getOperator() {
		return operator;
	}
	
	public void setOperator(Operator operator) {
		this.operator = operator;
	}
}
